Microsoft SQL Server

161K

Solutions

49K

Contributors

Microsoft SQL Server is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.SQL Server is available in multiple versions, typically identified by release year, and versions are subdivided into editions to distinguish between product functionality. Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning.

Share tech news, updates, or what's on your mind.

Sign up to Post

Our SQL Server network connectivity is broken! I can only get on it via a terminal from VMware.

Our server is set to a 192.168.0.x address, gateway 192.168.0.xxx. Ipconfig shows a 169.254.x.x address, I'm not sure why it is getting this.

Despite several re-boots I cannot ping it's IP address and several customer facing apps are failing. DNS looks OK, other servers with same settings are fine.

Can anyone help please!
0
The Ultimate Tool Kit for Technolgy Solution Provi
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

Good morning.  

I need help with SPSS syntax to export a .sav file from SPSS (v20) to SQL 2008 R2 using an ODBC connection.  

My goal is to write syntax that will export specific fields from an SPSS .sav file to an existing SQL table.

The requirements are to use syntax to copy the data from some fields (not all) in the SPSS file to an existing empty table in SQL Server.  I'm thinking ODBC connection is the least complicated route.  I have a working ODBC connection.

I think it's going to be something like:
SAVE TRANSLATE /TYPE=ODBC
/CONNECT (all my connection garbage)

but from here I need help to copy only the values in the specified fields to the correct table in my SQL database.

Thanks in advance for any help!
0
Dear concern,
Can I configure sql always on for 3 db in sql 2016 standard edition in non domain environment. Pls provide the step by step implementation document. Also is it possible the sql mirroring in sql 2016 standard edition in non domain environment for two db.

Can I configure mirr
0
Hello Experts,
Just wondering if there is a any opensource JAVA JAR file that I can use for a project that allows me to connect to a DB (like mysql or H2), create tables, insert data into tables, etc. Basically, I am looking for a solution which builds the queries itself when data is passed as parameters to a method. Any inputs really appreciated.
0
Hello

I'm having some trouble following this Microsoft document:

https://docs.microsoft.com/en-us/system-center/scom/upgrade-sqlserver-2017-opsmgr-1807?view=sc-om-1807

I have successfully upgraded my SCOM instance to 1807. I have also successfully upgraded the SQL database instance from 2016 to 2017, as that is now supported. However, I am unable to upgrade reporting services successfully. According to the release notes of SCOM 1807, upgrading from SQL 2016 to SQL 2017 is supported, but not for fresh installations. I find it curious then, that this upgrade guide instructs a removal of Operations Manager Reporting Services, and after upgrading SSRS, to install Operations Manager Reporting Services again. So, either I’m not reading this document correctly, or nobody has tried to follow it yet, including its creators.

How does one reinstall Operations Manager Reporting Services when using SQL 2017 Reporting Services? There is no 1807 fresh installation media as far as I am aware, so naturally, the 1801 installation media gives me this error when trying to reinstall:

The installed version of SQL Server could not be verified or is not supported. Verify that the computer and the installed version of SQL Server meet the minimum requirements for installation, and that the firewall settings are correct. See the Supported Configurations document for further information.

Would anyone have a workaround for this at all, or should I just go back to SQL 2016 SSRS?
0
i'm looking for a way to web scrape a simple web page by taking a csv list as my parameter and retrieving the html table on the next page through SSIS
The webpage is http://p2web.energy.dla.mil/pls/p2wp/dfsc_pkg.df_contract

so in the contract textbox i would put contract number item in my csv and retrieve the following html element

table
not wanting to use Zappysys. wondering if there are other tools out there that are free.
0
Hello All:

I have the following table structure (a result set inserted into a temp table):
Full Table
What I am trying to do is one of the two following (if I can have both options laid out that would be fantastic) Both involve removing columns based on the values (in the columns with Dxx, Pxx, and Fxx):

1)Create a new result set that has generic columns across and the results look lie the following:
Generic columns
2)Create a new result set where the columns are separated based on F, P or D as such:
Separated Columns
I'd love to have a solution for both, followed by 2 and then 1.

Many thanks!
0
In the process of migrating a SBS 2011 domain to Servre 2016, Exchange and SharePoint were removed to clean up AD.  However, a short time later several SP users cried ouch that some of their data had not been moved.  By then, the backups for the server had been aged off.  SharePoint was re-installed, but it also crashed all of the web services on the server.  Certainly getting those going would be great, but after a whole lot of time and energy, we tried a different tack: created a new, fresh SBS and am attempting to attach the content database from the original server.

The obvious way to do this, I believe, would be to back up the database, create a new instance on the new SBS, and import the data.  Well, that didn't go so well.  The attempt to back up the database on the old server keeps failing.  So plan B -> copy the data base to the new SBS, attach it as content database, but of course it has no usable credentials on the new server.

Here are my questions:

1. How do I take ownership of the database with credentials from the new server?
    I looked at some of the PowerShell commands but they require -identity and I can't come up with that from IE where I am supposed to see it I think.

2. How can I get it to backup on the old server, and would import then solve the problem?
    I have no idea why I am getting an error on backing this up; the newer content database backs up just fine.

3. How can I fix the web services on the old computer?
    Well this …
0
Here is my lovely pdo

$stmt = new Database();

				$query = "SELECT cp.id, cp.name, cp.field_type 
							FROM custom_properties cp
							WHERE cp.client_id = :clientID AND cp.viewable='1' AND cp.type = '1'
							ORDER BY cp.id DESC";
				$stmt->query( $query );
				$stmt->bind( ':clientID', $clientId);
		     	$stmt->execute();
				$demo1 = $stmt->all();

				foreach($demo1 as $customResult){
					$cusData['propertyId'] = $customResult['id'];
					$cusData['propertyName'] = $customResult['name'];
					$cusData['propertyType'] = $customResult['field_type'];
				

				$stmt = new Database();

				$query = "SELECT information FROM custom_information WHERE property_id = :propertyID AND contact_id = :contactID ORDER BY id DESC LIMIT 1";
				$stmt->query( $query );
				$stmt->bind( ':propertyID', $cusData['propertyId'] );
				$stmt->bind( ':contactID', $contactId );
		     	$stmt->execute();
				$result = $stmt->all();

				foreach($result as $anwer){
					$subrow['infomation'] = $anwer['infomation'];
				}//infomation result

				if($cusData['propertyType'] >=4 && $cusData['propertyType'] <=6) {

					$stmt = new Database();

								$query = "SELECT *
											FROM custom_property_values
											WHERE property_id = :propertyID
											ORDER BY id ASC";
								$stmt->query( $query );
								$stmt->bind( ':propertyID', $cusData['propertyId'] );
								$stmt->execute();
								$result = $stmt->all();
						$teststring = ["<select style ='width:100%;' 

Open in new window

0
what are the cautions we need take in SQL Server 2012 std( windows cluster 2012) and  Node1, Node2 are in cluster

as sql server 2012 sp4 patch upgrade we unable to install because of some installer files are missing, we tired to fix, but it is not working and  we are decided to go for SQL server Repair option on Node1

Pls let me know, what steps do i need to do..with a caution..on Node1

Pls note, once if it successful patched on sp4 on node2, after repair, then we will plan on node2.

Pls suggest. Thanks
0
Redefining Cyber Security w/ AI & Machine Learning
LVL 1
Redefining Cyber Security w/ AI & Machine Learning

The implications of AI and machine learning in cyber security are massive and constantly growing, creating both efficiencies and new challenges across the board. Join our webinar on Sept. 21st to learn more about leveraging AI and machine learning to protect your business.

SQL command text property value is invalid multipart name select . It occurs when I have the stored procedure and running the query to obtain data. I cannot view the data so I can see whether my paginated report in SSRS report builder is capturing the data I would like
0
I have an issue using an ADOQuery component with C++ builder.
If I execute a simple query "select * from Frames where FrameID = 1934411" the result is no record returned when Frames is a view.
However, if I copy the entire view contents into a table and then run the query against the table then the Record is found ?
The database is a Microsoft SQL Server version 12.0.5207.0

If I run the query on the view or the table using Microsoft SQL Server Management Studio then in both cases the record is returned.

Can this be fixed to use the view ?
0
I need to install SQL Server Standard 2014 , the main usage will be to activate the SSRS ( Reporting Services) and have it send automated scheduled emails to client. The main point I need t clarify is : can i install this edition of SQL server and have the SSRS running, on a normal windows OS ( Widnows 7, or Windows 10) .... or must it be a Windows Server OS ?
0
Hello experts,
Ldf file size of one of the DB reached  more than 60gb and I would like to reduce file size in order to avoid disk espace saturation. I checked the recovery model option and it is set up with full option.
I was wondering if I can go ahead by changing this option by simple and then reorganize log file to reduce as much as possible this file. I want to avoid database corruption or and unwanted consequence. What is the best practice to reduce ldf file?
Thank you very much for your help.
0
I am needing to deliver some js files to a desktop application that runs in a browser shell.  The reason I am doing it this way is I don't have a web server.  This has been running successfully for months until recently the cdn references to libraries like jquery no longer consistently download each time the app opens.  The app is running on windows 7 and uses IE 11 for the shell.  In replacement of a web server I thought about using SSRS since we have a db server.  I can't get the dba to turn on iis on that server as well but thought about placing the files on ssrs and then pointing the script tag src to http://ssrs-server/ReportServer?/Apps/Libraries/jquery.min.js.  When I test this I see the reference to the file in the temporary internet files folder so it appears to download but the initialization in code of jquery fails as if it were not available.  So maybe I don't fully understand what is being listed in the temporary internet files folder and how the app uses the js file from this location.  Does anyone have any suggestions as to what may be wrong or it there some type of conflict with ssrs in the opening of the file.  I can click directly on the file listed in ssrs in the folder view and it opens like a hyperlink showing the js file content.  Thanks for your input.
0
Hi Expert,
I need to create Degenerate Dimensions Table? Can any one show me how to do that?
0
Hi All

Just a clarification on DSN less connection, I have assembled the code below by first creating a file called AccountingFileDsn.dsn and the final code looks like below:

ODBC:Driver = ODBC driver 13 for SQL Server,SERVER = CHRIS\SQLEXPRESS;Trusted_Connection= Yess;

Well the above string works very well on my computer I'm able to do anything on the SQL Server Back-end no issue at all.

Clarifications required:

(1) Suppose I deploy my application to another computer called PETER (Server after installing Sql server express),will the above connection work? Since the new string was more likely to look like below:

ODBC:Driver = ODBC driver 13 for SQL Server,SERVER = PETER\SQLEXPRESS;Trusted_Connection= Yess;

For sure on all work stations the same ODBC driver 13 for SQL Server and Ms access run-time  will be installed, but again how is it going to locate the database Accounting without directing it ? I know this sounds very funny, I'm sorry I just want understand this ODBC thing, I will appreciate any further notes as well.


Regards

Chris
0
I have the following SQL query,

   SELECT Nodes.[Uri]  
    , Nodes.[DisplayName]  
    FROM Orion.Nodes AS Nodes

Open in new window

and its output is something like the following:
Uri                                                            DisplayName
swis://LLC1CCVORION01.corp.lcl/Orion/Orion.Nodes/NodeID=1475	aces.domain.com
swis://LLC1CCVORION01.corp.lcl/Orion/Orion.Nodes/NodeID=193	b1-a01-sw03.domain.lcl
swis://LLC1CCVORION01.corp.lcl/Orion/Orion.Nodes/NodeID=624	B1-AS01.domain.lcl

Open in new window


I wonder how can i query the sring "SQL" or "sql" within the DisplatName  ?

Thanks for your help
0
we hae some systems they are closing unexpectedly
0
Creating Active Directory Users from a Text File
LVL 8
Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

hi, Freeform Comments – Text Fact or Dimension?
0
Hi,
I just want to display an SQL Server table content onto an Excel sheet. I use standard Excel menu. Data -> From SQL Server -> Do the connection with SQL Server credentials -> Click the table.
All data are loaded successfully. But I have a problem.
Numeric data type (numeric(19,2) was rounded up in Excel.
For example: 3005581000009879 in SQL table will be displayed as 3005581000009880 in Excel. This happen to all the the records.
I tried to change the cell format to text (in Excel) without success.
How to fix this?
0
Hi All,

I have a data with date time value '2015-12-01 22:19:15.020'
I save it to  

 dim dteCrtDate as datetiem = DateTime.Parse(dtRowTransaksi("CrtDate").ToString)
 dteCrtDate = '#12/1/2015 10:35:49 PM#'

dteCrtDate = DateTime.Parse(dtRowTransaksi("CrtDate").ToString("yyyy-MM-dd HH:mm:ss.fffffff"))
Conversion from string  "yyyy-MM-dd HH:mm:ss.fffffff" to type 'integer' is not valid.

dteCrtDate.ToString("yyyy-MM-dd HH:mm:ss.fffffff") =  '2015-12-01 22:36:58.0000000', the problem at milisecs

How could I save to variable and format it into  '2015-12-01 22:19:15.020'?

Thank you.
0
Hello Guys....I Have a dataTable fetching data from sql server using PDO inner join method..
now I added dropdown menu to fetch data on dropdown dynamically and display the final data if the third box user already been selected..by this I only filter the table according to the user selected in the third dropdown box...Here is my code
index.php
<?php 
include ('include/db.php');
include ('include/head.php');
$stmt = $connection->prepare("SELECT * FROM branch"); 
$stmt->execute(); 
$result=$stmt->fetchAll();
?>
<!-- Add Outlet -->
<div class="modal fade" id="addoutlet" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog" role="document">
    <form method="post" id="outlet_form" enctype="multipart/form-data">
      <div class="modal-content">
        <div class="modal-header">
          <button type="button" class="close" data-dismiss="modal">&times;</button>
          <h4 class="modal-title">User New Data</h4>
        </div>
        <div class="modal-body">
        
        <div class="addoutletform" id="addoutletform"></div>
        
        </div>
          <div class="modal-footer">
          <input type="hidden" name="id" id="id" />
          <input type="submit" name="action" id="action" class="btn btn-success" value="Add" />
          <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
        </div>
      </div>
    </form>
  </div>
</div>

<!-- Add Branch -->
<div 

Open in new window

0
I have a recursive CTE that replaces multiple values from an expression, but it is too slow when there are many expressions.

    CREATE TABLE #table1(IdExpresion INT, expresion VARCHAR(MAX))
    CREATE TABLE #table2(IdExpresion INT, searchExpresion VARCHAR(50), replacementExpresion VARCHAR(50))
    
    INSERT INTO #table1(IdExpresion, expresion)
    VALUES(1, 'Mary had a little lamb'),
          (2, 'The new student, student_name has the following grades Math - math_grade, Science - Science_grade')
    
    INSERT INTO #table2(IdExpresion, searchExpresion, replacementExpresion)
    VALUES(1, 'lamb','dog'),
          (2, 'student_name','Joe Smith'),
    	  (2, 'math_grade','A'),
    	  (2, 'Science_grade','B+')
    
    ;WITH cte(IdExpresion, expresion, lvl) AS
    (
        SELECT t1.IdExpresion, t1.expresion, 1
    	FROM #table1 t1
        UNION ALL    
        SELECT cte.IdExpresion, REPLACE(cte.expresion, t2.searchExpresion, t2.replacementExpresion), cte.lvl + 1 
        FROM cte  
    	INNER JOIN #table2 t2
    	ON cte.IdExpresion = t2.IdExpresion
    	   AND CHARINDEX(t2.searchExpresion, cte.expresion) > 0
    )
    SELECT DISTINCT c2.expresion
    FROM (SELECT IdExpresion, MAX(lvl) AS lvl
          FROM cte
    	  GROUP BY IdExpresion) c1
    INNER JOIN cte c2
       ON c1.IdExpresion = c2.IdExpresion 
          AND c1.lvl = c2.lvl
    OPTION (MAXRECURSION 0);

Open in new window


Anyone have any advice? I am using SQL Server by the way
0
Installation failed for sql server 2012  sp4 upgrade for one of the cluster node1.. and another node2 is working fine
see the error msg sql server 2014 sp4 upgrade failed cached msi

1. even copied  sql_engine_core_inst  from C:\sqlpatches\sp4\x64\setup\sql_engine_core_inst_msi

to %windir%\installer\
with

cached msi file 7b2f1fe.msi


2.  https://github.com/suyouquan/SQLSetupTools/releases/
FixMissingMSI_V2.2ForNET35.zip

and fixed all..

Still the same error

Not sure, what should i do
0

Microsoft SQL Server

161K

Solutions

49K

Contributors

Microsoft SQL Server is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.SQL Server is available in multiple versions, typically identified by release year, and versions are subdivided into editions to distinguish between product functionality. Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning.