How to select specific column in SQL Queries?

I want to select a specific column from a table.

My Code is 

SELECT {TableName}.[Column1] from {TableName}

and Get error that says "Column count doesn't match structure attribute count"

Hi Wilbye,

You will require to create a structure with data type of {TableName}.[Column1] and then use it in the output structure of your SQL query.

This will execute your query for sure.

Regards,

Nikhil 

Wilbye Descalsota wrote:

I want to select a specific column from a table.

My Code is 

SELECT {TableName}.[Column1] from {TableName}

and Get error that says "Column count doesn't match structure attribute count"

 

 Hi,


You are getting an error bcoz the output structure not matched. to solve this issue create a new structure with desire columns in your case one attribute in structure and bind that structure as an output.


Thanks

Hi Willbye,

You need define cloumn in select statement to correspond to output structure.

Correct way:


Hope this will help you!

Vijay M-

All of the replies were right, structure is required for the columns to be selected. Thank you guys