I want to get the row value of a query....
Dear friends,I want to do a script where I have to get the current position of the cursor in sql db.sql= “Select * from Mytab where description=” &$tagsearch&“ “and I want to know exactly the...
View ArticleStoring multiple fields in one table with the same concept?
Hi ya there,I'm building the physical db for the classical recipes app..Main issue comes when I need to store all the ingredients for one recipe concrete. My aim is that the end user can look for one...
View Articleerror 41105 while working with Always on in sql 2012
Hi I am upgrading to Sql 2012 and tried to work with High availability group concept of Sql 2012.I need to know 2-3 things.When I configure AO for sql 2012 I do not need any shared storage I believe,...
View ArticleStoring multiple fields in one table with the same concept?
Hi there,I'm building the physical db for one recipes app..Main issue comes when I need to store all the ingredients for one concrete recipe. My aim is that the end user can look for one or more...
View ArticleHow to generate script with only 5 rows in table
Hi,I need to get generate scripts to create a database with data. Since the DB is that much size, I don't want to take all records of the table but 5 or 10. Is there any option to generate scripts with...
View ArticleStoring value in localvariable from dynamic sql in sql
declare @EndDate varchar(50) set @EndDate = '2014-11-17' declare @monthend varchar(50) set @monthend = 'select' + ' '+ 'MONTH('+ ''''+@EndDate+''''+')' declare @flag int set @flag = exec @monthend...
View ArticleIS IT POSSIBLE TO EXEC SP INSIDE SP AND EXECCUTE IF BY THE R
CONTEXT : I WANT TO UPDATE THE FIELD OF TABLE 'A' TO FALSE AND I WANT TO EXCECUTE ANOTHER STORED PROCEDURE AND BASED ON ITS RETURNED VALUE I WANT TO CHECK THE IF CONDITION AND EXECUTE ANOTHER...
View Articleimport export in different encoding
Is there a way to change an Import/Export Wizard's output in UTF encoding. Please help.
View Articleowner but cant
I am the owner of a dbase entity on sql but when I try to drop a table it says I do not have permissions. Why? I am using 2008 SQLEXPRESS and the sql code is DROP TABLE table_name. If I right click...
View ArticleDoes the Class Word always have to be the last word in column name? What...
Sometimes we are required to store both a US and a metric column in the same table. Is it ok to use the unit type as a suffix to the class word like AreaSqMi and AreaSqkm in the case of watersheds...
View ArticleChange Default File group
Hi All,I have 500GB database with 7 Data files.One data file is on X: Drive - Primary file group - Default- Has only one file.Other five on Y: Drive. - Secondary file group SEC_1I have added a new data...
View ArticleMeasuring IO Latencies
Hi all,In some blogs I have seen that people use dm_io_virtual_file_stats to calculate read and write latency like this:[io_stall_read_ms] / [num_of_reads]and[io_stall_write_ms] / [num_of_writes]I...
View ArticleCannot use SchemaBinding in SQL Server 2012 instance
In a new database created by code CREATE DATABASE AUS_WEEKLY, when I try to create a view with schemabinding, I get the error Msg 4513, Level 16, State 2, cannot schema bind view. In another instance,...
View ArticleMaintenance Solution on Express edition
Can any one tell the me the way of Maintenance Solution on Express edition?
View ArticleDatabase design
Say I have a table that contains information about servers. As new servers come online, this table is populated with information about the servers. Now, assume that the server name is unique, and...
View Articlewhat design to split bank transactions into more detail? (in budget database)
Current Design:* I have a budget/finance tracking database I’m building * It has a BANK_TRANSACTIONS table where I load in transactions from various bank accounts * It there has an ALLOCATIONS table...
View ArticleNeed help with scripting
Hi, I need some advice in building a stored procedure which will calculate commission for salesman.. Below are the rules:We have different categories of salesman who receives commission, they have a...
View ArticleValidation text
How can i create validation text for a field of table???for ex. , if value of the field is greater than 90 , show msg box "value is not correct"thanks .
View Article