What bit stand for in sql? [closed] - sql

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
when i take a data type as bit and when i insert 0 or 1 in that columns of the table then it give error. so please tell me how to remove the error?

Your question is missing a lot of required details.
If this is Microsoft SQL Server and you are entering them through the Table Editor in SSMS you need to type "True" or "False"

Bit means boolean, as the other two responders have said.
However, boolean values can be displayed in various ways. 1 and 0, true and false, 'Yes' and 'No' are examples. Try each of these, and if you're still not getting anywhere, let us know!
Good luck.

Related

SQL does replace and CAST on select affect the Database? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I am creating a view and I was asked to do a 'replace' and a 'cast', so as an example:
SELECT CAST(qtyshipped AS INT) AS 'QTYShipped', REPLACE(itemval,'.','')
FROM Database
Within the view, should not actually change the information in the database but just in the query correct? (It works perfectly in my sandbox server but i just want to confirm)
Not a dumb question at all. And the answer is yes, it only changes the result of the query, the underlying data will remain the same.
That is already a good query. But I need to tell some points with you.
REPLACE function is case-sensitive. Although I've seen in your code that you are only replacing period.
Why is your column qtyshipped is not in numeric type? You should have change that into numeric. So you won't need casting which may lower the performance.
It will not affect your database since your are only executing SELECT not UPDATE.

SQL Fiddle moved to SO Data? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
This question is totally unacceptable and will be closed but...
Has SQL Fiddle been amalgameted into Stack Exchange? For example in HERE
Also - THIS is crazy - Am I correct in saying this is sql that is querying SO itself?
(... can't wait to play.)
First, such questions should rather be in meta.
Second, the data explorer has been around for some time now; it's not about executing arbitrary SQL code but for queries against the SO database.
See meta for more questions around the data explorer: https://meta.stackexchange.com/questions/tagged/data-explorer

Dynamic code generation and execution without writing code to database [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
Is it possible to generate ABAP code and execute it in memory without writing code to DB?
Yes. Use Google. Use Google. Use Google. Use Google. Use Google. (I have to write at least 30 characters although I really don't have anything else to say besides that wanting to generate code dynamically is usually a sign you're on the wrong track.)

why text or ntext is not recomended for use in sql server [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
please discuss the reason why why text or ntext is not recomended for use in sql server. thanks
They are deprecated, won't work in future versions and working with them is a pain compared to the replacement datatypes (varchar(max) and nvarchar(max)) as most string functions don't work with them.

How to make a view in SQL Server? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
I have more tables and I want to merge that some table for getting result.....
How can I do?
Views is just some sort of "stored query". It can be defined as:
CREATE VIEW viewname AS SELECT <the rest of select query here>
More details at msdn:
http://msdn.microsoft.com/en-us/library/ms187956.aspx
http://msdn.microsoft.com/en-us/library/aa214068(SQL.80).aspx
CEATE VIEW.
The rest of teh syntax is in ..... the documentation.
And this question is neither related to C# nor C++. It also does not care what you ate for breakfast. SQL works with strings the server interprets, and the langauge has no matter how the server does that.