I've got an .rpt file that I did not write and can find no documentation about. I want to be able to review the SQL that is generated from this report so that I can figure out, well, what data it was pulling and what WHERE clause parameters were used.
I can open it up and see the report layout. But when I select Database|Show SQL Query...
Does anyone know of a way to "extract" the formulas for all calculated members of a cube into some kind of flat, readable file? Alternatively, a less-painful method of getting an overview of the code than using Analysis Services' Cube Editor and clicking on each Calculated Member would be helpful. Yes, I'm new to MDX. Many thanks!
...
I am looking to add a (local, not online) high scores table to my Android app and I wanted to get some insight on the best way to approach the problem.
I have a list of users (right now being saved out to a file and read back in as an array of User objects), and the high scores need to reference this data to populate the table with the ...
i am doing sql server backups like this in script:
BACKUP DATABASE databasename TO DISK = `path'
since this backup is going to be automated, how do i insert today's date into 'path' ?
...
Inserting multilingual data into a SQL 2008 database (nvarchar field) I notice that it seems to lose some special character marks.
e.g.
INSERT INTO [dbName].[dbo].[tbl_Question_i18n]
([QuestionId]
,[LanguageId]
,[QuestionText])
VALUES
(@lastinsertedquestionid
...
I have data in a table that looks like the following sample data:
varchar(20) | DateTime | varchar(20) |varchar(255)
_Serial_Number__|_Date_Time______________|_System_ID___|_Test_Result________________
C035993 0703 05 |2005-08-18 13:43:33.717 |VTI-Chamber1 | (BLUE) TEST ABORTED, LEAKFP SPUN DOWN
C035993 0702 05 |2005-0...
I have a table that has a version timestamp column. No creation date. Running the visual studio wizard with the localdatacache. It creates 2 triggers one for insert and one for delete. It also create an additional column CreationDate => DEFAULT VALUES TO @@DBTS + 1.
First confusion : It has created and additional column with a default v...
I'm running this statement:
declare @path varchar(255), @mydb varchar(50)
SELECT @mydb = 'timeclockplus'
select @path = 'C:\Program Files\Microsoft SQL Server\MSSQL.2\MSSQL\Backup\' + @mydb + '-' + convert(varchar(8),getdate(),112) + '.bak'
BACKUP DATABASE @mydb TO @path
and getting this error:
Msg 3206, Level 16, State 1, Line 4
No ...
Hello,
I am have 3 tables. I am using Oracle 10g.
I am trying to get records from Table A where rows don't exist in Table C
AND if there is a corresponding row in Table C then it should meet condition where C_PRIAMRY = 1.
Table_A
A_ID, A_NAME, A_STATUS_CD, A_STATUS_DTE
----------------------------------------
1 test1 NM ...
Hi all,
I know this question could have passed a few times here but I haven't really found a workaround whatsoever. Also could my question be a little different.
Situation is: I have a table with 130 columns (+100.000 rows), and the number of columns will even increase in the future. For this reason I would like to define the selection...
I would like to create a SQL query, which does the following..
- I have a few parameters, for instance like "John","Smith"
- Now I have a articles tables with a content column, which I would like to be searched
- Now, How can I find out the rows in the articles table, which has the any one of those values("John","Smith")
I cannot use...
SHORT VERSION:
What is the best way of casting "5-" as a number for storing into a table as a number?
LONG VERSION:
Here is the issue, I have a table I am reading from primary made up of VARCHAR2s. I am grabbing the data from some fields and storing them in another table without modification. In one field I am getting "5-" and trying to...
Here are the two designs I have : (I'm using SQL Server 2005)
Constellation Schema :
http://img84.imageshack.us/img84/7206/constellation.jpg
Star Schema :
http://img692.imageshack.us/img692/971/starme.jpg
I need to build a report which shows ProjectID,ProjectName,Hours,isImpacted,isRequesting for a given line of business(LO...
Is there a way to add a constraint in SQL Server 2008 that will verify that if a user try to enter a value in a column A, it can only if column B is null and vice-versa
Example
if A is NULL, B can have a value
if B iS NULL, A can have a value
A and B can't have value at the same time
...
Is there a way to downgrade a database, that has been created on SQL Server 2008 R2, to work on an older version of SQL Server 2008 (RTM/SP1).
...
I have a result that gives me a range of values to query from my database:
Start End
----- ---
1 3
5 6
137 139
From those, I need to query the database for the records in that range, which might return something like:
Id Name
----- ------
1 foo
2 bar
3 baz
Id N...
Unlike programming languages, SQL doesn’t allow variable to be assigned a value using the following syntax ( instead we must use SET or SELECT ):
@i=100; //error
Is there particular reason why SQL doesn’t allow this?
thank you
...
I have an application where a user can upload files and associate the files with a project. The projects can be duplicated. Here is an example of an object:
Public class Project{
Int ProjectId{get; set;}
string ProjectName{get;set;}
List<int> FileIds{get;set}
}
When I go to duplicate the project, say, what is the best way ...
I have two tables. In the one table I have a list of dorm rooms with maximum occupancy like so:
dorm_building | dorm_room | max_occupancy
Then I have a list of students and the room they are assigned to like this:
people_id | people_name | dorm_building | dorm_room
I want to create a table that has a row for each potential occupant...
I have a stored procedure that I'm positive of has no errors but I recently deleted the table it references but imported a backup with the same name exactly and same column settings (including identity) that the previous one had but now it doesn't work.
Is there any reason that having deleted the table but importing a new would break t...