2,935 Topics
| |
Hi all Just a quick question from a noobie! If i have a DB mirrored...if I apply schema changes to a table in the primary mirror db...will the secondary mirror DB get updated? or is it just data that get's mirrored? Thanks in advance | |
I would like to add a field from a table to an existing view without changing the structure of the existing. Below is the statement for the existing view and the result [CODE]SELECT (SELECT COUNT(*) AS Expr1 FROM dbo.BillsSections WHERE (BillIndex = a.BillIndex) AND (Type <> 7) AND (BillSectionIndex > … | |
Hi, the Microsoft SQL Server version is 2000 Basically I want use a basic regular expression but can't seem to get the syntax right. i want to compare ID_short = ID_Long ID_short is a truncated version of ID_Long, and I want to search on the beginning only (hence I can't … | |
please help for MsSQL stored procedure for ASP.net/C#. Inside stored procedure i used 4 different statements in where clause . first one is working but last 3's are not . Statements are given below- FILENAME LIKE ''%'+ @FILENAMETEXT +'%'' FILENAME LIKE '+ @FILENAMETEXT +'%'' SUBSTRING(FILENAME,1,4)='+@FILENAMETEXT+' LEFT(FILENAME,4)='+@FILENAMETEXT+' bunch of code for … | |
Hello, Right now i am running SQL 2005 server and using Visual studio C# 2008 to program. I sadly have a Windows Vista professional, 320gbhd, 2gb ram, intel duel core processor, The problem is on C# you can attach a database to your program to retrive or import information from … | |
I would like to SUM two fileds from different rows from the same table but I don't know how to do that. E.g. BillingTransactionsIndex CreateDate UserType UserIndex TransType Reference Total Balance 2 6/5/2008 15:02 1 51 1 150 -288.2 -288.2 5 6/8/2008 11:55 1 51 1 157 -1.58674 -289.787 In … | |
Hello everyone I am building on a little project in .net, but I have ran into some problems on database - level. I am creating a view with data from a couple of tables. It all revolves around my main table (let's call it 'main' for now). In 'Main' there … | |
| |
Hey guys, I've gotten hold of a MS SQL Developer edition, installed it completely, now running off the HDD. However when I go to Start> Programs> MS SQL Server 2005... I only get these options: Notification Services Command Prompt SQL Server Configuration Manager Error and Usage Reporting Surface Area Configuration. … | |
Hello all, i have got an issue with a client here, who is running an internal CRM system. we need to get information into our Webserver (Linux-MySQL5) database (dealer lists, product lists, ....) and this information is stored in the CRM. but the CRM is Windows-MSsql. The output is .DAT … | |
Hi I'm migrating from Oracle Sql to MS Sql. I'm trying to write an mssql query that will pull all rows from a tableA but only if row in tableB = apple. In other words the table might look like this: tableA tableB Joe apple Joe orange Joe peach Fred … | |
Hi All, When I run the query: [B]select (100/50)[/B] It give me "2"... good. But when I run the query: [B]select (50/100)[/B] I was expected it will give me 0.5... but it gives me 0 instead? Why? and How can I get the "0.5"? | |
I need to create a query of records in one table along with a count of how often those records occur in 2 other tables and the difference between the counts. | |
i have 2 tables : 1.Ms_Menu Menu_Id,Menu_Name 001 | Menu1 002 | Menu2 003 | Menu3 2.Tbl_User User_Id,User_Name,Menu_Id User1 |Name1 |001 User1 |Name2 |002 User2 |Name2 |002 i want to joined 2 tables using UNION(or other way if works is fine->left/right join) my coding : [code=sql] SELECT User_Id,User_Name,Menu_Id,'' Menu_Name FROM … | |
I am trying to create a sql statement like set @sql = 'select @stage1 = count(MY_ID) From VW_OPEN where ' + @filter and run it with exec (@sql) However this generates an error Must declare the variable '@stage1'. If I run statement select @stage1 = count(MY_ID) From VW_OPEN the var … | |
I need to write a query that will pull my products and price. However each of the products have multiple prices and I want the price with the most recent date. I have tried the following query but it doesn't work. Can someone assist me. I'm fairly new to sql … | |
Dear Friend I am trying to perform the flowing tasks using the following SQL statement in Microsoft Access but they don’t work. I wonder if someone could help and tell me what is wrong with my Statements. Whenever I run these statements it will not create the query. [B]Task 1: … | |
Hi. Can anyone tell me how to populate items in listview? I need to call a column in a database to load all its list. | |
I will try to make this as simple as possible. Any help would be greatly appreciated. I have 3 tables like below. tblEmployees ----------------------------------------- EID | Name | 1, John 2, Bob 3, Steve 4, Brian 5, Joel 6, Lance ----------------------------------------- tblTraining ----------------------------------------- EID | JOB | 3, 1 4, … | |
I am using SQL Server 2005, I have some select and update statements in my query with WHERE clause I want to prevent these queries from SQL injection attacks. What are the steps and precautions to be taken for SQL Injection attacks? Does anybody have suggestions? Thanks in advance, | |
Greetings, I am trying to do a reconnect type of thing for when sqlserver disconnects me i check and reconnect to execute a query. here is some code that i wrote, I really don't know what to use since there is not isconnected method or reconnect method in pymssql. Any … | |
Hello, i have a database that came with MYSQL statements to get it working but we are using MSSQL and have managed to convert a large proportion of them but there are two statements we are having trouble with and wondered if anyone could help. The first is below: [CODE]SELECT … | |
Hi. Can anyone tell me how to create a mobile database and application using SQL Server Management Studio Express? | |
hey guys, i dont suppose you know how i can go from: id.............result ---------------------- 1..............Pass 1..............Pass 1..............Fail 1..............Pass 1..............Fail 2..............Pass 2..............Pass 2..............Fail to this table: id...........pass......fail 1............3.........2 2............2.........1 my current query is simply select id, result from results I just want to display the total number of occurrences of a … | |
I continue to get this message though there are no duplicate keys in the table/s I am transferring into the new table I am creating using DTS. I created a query to look to duplicate primary keys and did not get any duplicates after running it. The DTS is a … | |
I'm getting this error message [B]An exception occured while executing a Transact-SQL statement or batch (Microsoft.SqlServer.Express.ConnectionInfo) CREATE DATABASE permission denied in database 'master'. (Microsoft SQL Server, Error:262)[/B] When I try to create a new database from the right click option on the master DB. I think this is a permission … | |
After creating the table i tried to specify the unique key constraint in sql server 2005 but its asking for the expression. I don't know what to give in that expression. can u please help me out in this. thanx in advance. | |
Hey guys, I'm working with a database at the minute (not my own), and the two tables are as follows: ---------------------- Customer ---------------------- CustomerID Agent 1 55a 2 97t 3 87f 4 44g 5 63l 6 21s ---------------------- ----------------------------------- Details ----------------------------------- ID DetailName DetailValue 1 FirstName John 1 LastName Smith … | |
if i use the query [CODE]SELECT iditem, CONVERT(char(20), dt, 105) FROM planeamento[/CODE] it works just fine.. but in this case the dt (date) field is not recognised.. [CODE]SELECT planeamento.iditem, idmodelo, item_planeamento.idproduto, item_planeamento.idpele, cor, ordemfabrico, qtd, CONVERT(char(20), dt, 105) FROM produto INNER JOIN item_planeamento ON produto.idproduto = item_planeamento.idproduto INNER JOIN planeamento … |
The End.