Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Selct query error

Former Member
0 Likes
13,014

Hi all I made a select query and its giving me a strange error.

"Unknown column name "a~BUKRS". not determined until runtime, you

cannot specify a field list."

Plz suggest...

select a~bukrs

a~fkdat

a~spart

b~vbeln

b~posnr

b~matnr

b~zzpernr

c~werks

b~zzfname

b~zzlname

b~ps_psp_pnr

b~spart

into table git_data

from ( vbak as a join vbap as b

on avbeln = bvbeln )

join pa0001 as c

on

cpernr = bzzpernr

where a~vbeln in so_vbeln

and a~bukrs in so_bloc

and b~spart in so_bu

and b~ps_psp_pnr in so_proj

and b~zzpernr in so_epno

and a~fkdat in so_per

and a~fksto ne 'X'

and a~fkart ne 'S1'

and c~werks in so_loc

and c~endda in '99991231'.

1 ACCEPTED SOLUTION
Read only

ThomasZloch
Active Contributor
3,996

(In ECC 6.0) there is no field BUKRS in VBAK, only BUKRS_VF.

Thomas

5 REPLIES 5
Read only

ThomasZloch
Active Contributor
3,997

(In ECC 6.0) there is no field BUKRS in VBAK, only BUKRS_VF.

Thomas

Read only

Former Member
0 Likes
3,996

Hi,

The error is because the table VBAK i.e a does not have field called BUKRS.

Regards,

Sujit

Read only

Former Member
0 Likes
3,996

>"Unknown column name "a~BUKRS". not determined until runtime, you

There is no field BUKRS in VBAK that is the reason you are getting the syntax error.

select a~BUKRS_VF "Try this

a~fkdat

a~spart

b~vbeln

b~posnr

b~matnr

b~zzpernr

c~werks

b~zzfname

b~zzlname

b~ps_psp_pnr

b~spart

into table git_data

from ( vbak as a join vbap as b

on avbeln = bvbeln )

join pa0001 as c

on

cpernr = bzzpernr

Read only

Former Member
0 Likes
3,996

Plz change your query as per bold area

select a~bukrs_vf

a~fkdat

a~spart

b~vbeln

b~posnr

b~matnr

b~zzpernr

c~werks

b~zzfname

b~zzlname

b~ps_psp_pnr

b~spart

into table git_data

from ( vbak as a join vbap as b

on avbeln = bvbeln )

join pa0001 as c

on

cpernr = bzzpernr

where a~vbeln in so_vbeln

and a~bukrs_vf in so_bloc

and b~spart in so_bu

and b~ps_psp_pnr in so_proj

and b~zzpernr in so_epno

and a~fkdat in so_per

and a~fksto ne 'X'

and a~fkart ne 'S1'

and c~werks in so_loc

and c~endda in '99991231'.

Read only

Former Member
0 Likes
3,996

Hi Shashank,

As others have also said, the field name is as BUKRS_VF in table VBAK that is Company code to be billed.

So change BUKRS to BUKRS_VF in your select query whether is are working in ECC 6.0 or ECC 4.7.

With luck,

Pritam.