Search
Friday, July 04, 2008 ..:: Integrated Resources » User Preferences » Database Maintenance ::..   Login
Site Navigation

 Network & Database path settings Minimize
Database path settings

The factory default database path settings are as shown in the figure below.

C:\Program Files\Chirosoft\Data\Chirosoft.mdw

If you are not able to logon to MyEMR for Windows, you should check the settings in Database32.

You can access Database32 from the Start menu, by selecting:

    Start->All Programs->Software Motif->Database32

If your database settings are not correct, you may get two errors loading Database32, so you should click through the two errors.

In this figure, note that the third tab, i.e., the "location" tab is selected.

Sharing the MyEMR for Windows files over a network.

1.    On the server, create a "share" on the C:\Program Files\Chirosoft folder, called "CHIROSOFT".  Please note that this share must provide adequate network read/write/execute permissions to all intended users of MyEMR for Windows.

2.    Now make changes to each networked workstation.  Using the example that your server is named "SERVER", change the "Public Workgroup file" to be named "\\SERVER\CHIROSOFT\Data\Chirosoft.mdw".  This should be done by using the "..." button to browse your network for the server and its available "shares".  Your server network name is probably not "SERVER".  Your server name can be found by browsing your network or in the Control Panel under the System category and Computer Name or Network ID, depending or  your operating system.

3.    Never use networked drive letter mappings for these settings.  If the hard disk is not local, you must use the UNC network naming convention, as in "\\SERVER\CHIROSOFT\Data\Chirosoft.mdw".   


 Print   
 Step-by-Step: Database Upgrade Minimize

When installing an upgrade, and the database will not upgrade automatically:

  1. From "My Computer", browse to the location of your cs_pub.mdb file.  The factory default location for this file is the C:\Program Files\Chirosoft\Data\Main folder.  For Windows Vista, the factory default location is the C:\Users\Public\Public Documents\Chirosoft\Data\Main.
  2. Double-click on the DBRebuild.exe file.
  3. Click "Repair".  The upgrade may take a few seconds to a few minutes.
  4. When complete, you will receive the message "Database upgrade complete and renamed."
  5. If you receive a message other than a successful message, immediately contact support@softwaremotif.com to open an eTicket.

 Print   
 Database Rebuild or Repair Minimize

Rebuilding or manually upgrading a database

The database maintenance tools (for rebuilding a database or manually upgrading) are distributed with EMR Datacenter and MyEMR for Windows.

These maintenance tools are located in the factory default location of:

   C:\Program Files\Chirosoft\DBRebuild

To rebuild or manually upgrade a database follow these steps:

  • Identify the SQL design of your database prior to upgrading it by going to Start->All Programs->Software Motif->Database32.  Click the Version tab and note the Public number.  It will be a number such as 9.0.286*.  Make a note of this number.  This is the current database SQL design.
  • Browse to the C:\Program Files\Chirosoft\DBRebuild folder
  • Right-click over the blank database template in this folder which matches the current database design prior to upgrade, for example BLANK90286.mdb*, and choose copy from the menu.
  • Browse to the C:\Program Files\Chirosoft\Data\Main folder (or otherwise desired site folder).  While in that folder, right-click and choose paste.

Figure 1

  • Now you are ready to rebuild the cs_pub.mdb data into the new BLANK90286.mdb* template.
  • Browse back to the C:\Program Files\Chirosoft\DBRebuild folder.  Double-click on the file named DBRebuild.exe.  You will see a program appear as in Figure 1.
  • Use the browse buttons as indicated by the bright blue arrows.  Browse to the file names indicated for the "Source Database" and "Target Database".
  • Press the Begin button.
  • The upgrade process will run.  You will receive two "Error 3666" messages, which are expected and can be ignored.  You should not get a third error message of any kind.
  • You will receive a message of Rebuild Complete.
  • Browse to the C:\Program Files\Chirosoft\Data\Main folder.
  • Rename the current cs_pub.mdb file to another name, such as cs_pubSAVE.mdb.
  • Rename the rebuild template, such as BLANK90286.mdb* to cs_pub.mdb, which is your new rebuilt database.
  • Note:  Different versions of MyEMR for Windows and EMR Datacenter may distribute blank databases that are different versions.  You should always rebuild your existing database into the template installed in:

         C:\Program Files\Chirosoft\DBRebuild.

 

* For purposes of this example, we'll use the SQL design of 9.0.286.

 


 Print   
 Database Backups Minimize
Backing up EMR Datacenter and/or MyEMR for Windows:

1.  From the menu of either EMR Datacenter or MyEMR for Windows, choose:

     Help->Backups

2.  You will be presented with a dialog box as in the figure below.  Note:  This figure indicates *your* backup folder and the folder in the figure below is only a sample.  This indicates that path that you want to backup.

3.  If you have further questions about this article, please contact support@softwaremotif.com.  Thank you!


 Print   
 Advanced: Database Queries Minimize

Database maintenance queries

The database of MyEMR and EMR Datacenter database can be modified and maintained by advanced users who have advanced needs using SQL (structured query language) statements.  These SQL statements should only be run with express permission from technical support and most importantly, only after a verifiable data backup.  Most of these SQL commands are not reversible and if run by mistake, will require restoring a data backup.

You *must* be logged onto the MyEMR® Suite Attendant for the desired database.  The program, SQLExec32.exe is not intended for use without the direction of technical support.  With that notice, you can find SQLExec32.exe in the following folder:

  1. Always make a data backup immediately before running a query using SQLExec32.exe.  These queries are not reversible.
  2. C:\Program Files\Chirosoft\Applications\SQLExec32.exe - just double click on it.
  3. Copy the desired SQL command from the table below and paste into the SQL Exec Free Form window as in the figure below.
  4. Press the "Execute" button.
  5. You may now close the SQL Exec application.

 

Description

SQL Command (Drag select and copy to your clipboard.)

Reset the internal database modified date so that ThirdPartySync will force a refresh of all patient demographic data.

UPDATE CP_DP SET CP_DP.ReplicationModified=#1/1/1980#
 

Force all patients to have a receipt selection of "NO" in the Financial tab of the Patient General Information window.

UPDATE tblFinancial SET tblFinancial.Receipt = 0;
 

Force all patients to receive statements only when a minimum amount is due.

UPDATE tblFinancial SET tblFinancial.Statement = 2;

Initialize all patients to receive "Gentle" late notices, no receipts by default, and only "Minimum Due" patient statements.

UPDATE tblFinancial SET tblFinancial.LateNotice = 1, tblFinancial.Receipt = 0, tblFinancial.Statement = 2;

Set all diagnoses to an "Inactive" status.

UPDATE tblDiagnosis SET tblDiagnosis.Status = "Inactive";

Change all insurance payer types from Internet Disk Image to EClaims EDI Image.

UPDATE tblCarrier SET tblCarrier.FormType = 7
WHERE (((tblCarrier.FormType)=2));

Change all insurance policy form types from Internet Disk Image to EClaims EDI Image.

UPDATE tblThirdParty SET tblThirdParty.FormType = 7
WHERE (((tblThirdParty.FormType)=2));

Change all existing insurance claims Internet Disk Image to EClaims EDI Image.

UPDATE tblClaimCarrierDetail SET tblClaimCarrierDetail.FormType = 7
WHERE (((tblClaimCarrierDetail.FormType)=2));

Revert the form types of all insurance policies and insurance claims to the default form type defined in the insurance payer catalog.  (Advanced:  Make a backup of your data before executing any queries.)

UPDATE tblCarrier INNER JOIN (tblThirdParty INNER JOIN tblClaimCarrierDetail ON tblThirdParty.Created = tblClaimCarrierDetail.CarrierCreated) ON tblCarrier.ID = tblThirdParty.ID SET tblThirdParty.FormType = [tblCarrier].[FormType], tblClaimCarrierDetail.FormType = [tblCarrier].[FormType];

Change all insurance policy form types from Internet Disk Image to CMS-1500 type.  Notice:  These are two update queries.

UPDATE tblClaimCarrierDetail SET tblClaimCarrierDetail.FormType = 0
WHERE (((tblClaimCarrierDetail.FormType)=2));

UPDATE tblThirdParty SET tblThirdParty.FormType = 0
WHERE (((tblThirdParty.FormType)=2));

Change all form types from CMS-1500 to E-Claims EDI Image type.  Notice:  These are two update queries.

UPDATE tblClaimCarrierDetail SET tblClaimCarrierDetail.FormType = 7
WHERE (((tblClaimCarrierDetail.FormType)=0));

UPDATE tblThirdParty SET tblThirdParty.FormType = 7
WHERE (((tblThirdParty.FormType)=0));

In the insurance payer catalog, set form type to CMS-1500 where the form type is undefined.

UPDATE tblCarrier SET tblCarrier.FormType = 0
WHERE (((tblCarrier.FormType) Is Null));

In the patient's insurance policies, set form type to CMS-1500 where the form type is undefined.

UPDATE tblClaimCarrierDetail SET tblClaimCarrierDetail.FormType = 0
WHERE (((tblClaimCarrierDetail.FormType) Is Null));
 

 

For insurance claims that are created, but have no form type defined, set form type to CMS-1500.

UPDATE tblThirdParty SET tblThirdParty.FormType = 0
WHERE (((tblThirdParty.FormType) Is Null));

Remove all patients from the sign-in list of MyEMR and/or EMR Datacenter.

DELETE tblCheckIn.*
FROM tblCheckIn;

Mark a visit status as "Inactive" so that it doesn't appear in the Pocket PC frequency list.

UPDATE tblCPVVisitStatus SET tblCPVVisitStatus.Inactive = True
WHERE (((tblCPVVisitStatus.ID)="1/W-1W"));
 

Mark all patients to have a status of "Inactive".

UPDATE CP_DP SET CP_DP.STATUS = "Inactive";

Force all insurance payers to print the TIN/EIN number instead of the provider's SSN number.

UPDATE tblCarrier SET tblCarrier.TaxID = 1;

Force TOS = 1 for all service category transactions whose TOS is blank.  Some users may elect TOS = 9 for "Other medical service" by modifying the SET portion of the query.

UPDATE (tblProcedure INNER JOIN tblTransaction ON tblProcedure.ID = tblTransaction.ID) INNER JOIN tblProcedureCategory ON tblProcedure.Category = tblProcedureCategory.ID SET tblTransaction.TOS = "1"
WHERE (((tblTransaction.TOS)="") AND ((tblProcedureCategory.Type)="S"));

ADVANCED MAINTENANCE:  Delete all generated SOAP notes and report from the active database.  This may be applicable only to a new user who has been using practice visits on a live database.

DELETE CP_DSIRTF.UID
FROM CP_DSIRTF
WHERE (((CP_DSIRTF.UID)<>0));

ADVANCED MAINTENANCE:  Delete all symbolic subjective, palpation, assessment status and plan modality records from the active database.  After running this query, the user must use the Start->All Programs->Software Motif->Database utility to run the action of "Create ActiveSync Findings" and re-synchronize their Pocket PC.

DELETE CP_DSD.RecordID
FROM CP_DSD
WHERE (((CP_DSD.RecordID)<>0));

Inactivate all procedures except accounting codes.

UPDATE tblProcedure SET tblProcedure.Status = "Inactive"
WHERE [tblProcedure].[Category]>18 And [tblProcedure].[Category]<90000000;

Change the EMR Datacenter plans of 1H, 3H, 5H, etc., as plans available to MyEMR for Windows / Pocket PC.

UPDATE tblCPVModality SET tblCPVModality.Owner = "*PUBLIC"
WHERE (((tblCPVModality.ID) Like "1*" Or (tblCPVModality.ID) Like "3*" Or (tblCPVModality.ID) Like "5*"));

Delete all procedure codes whose status is "Inactive".  Do not run this without a data backup and the supervision of technical support.  This should be used by new users only prior to entering any transactions.

DELETE tblProcedure.Status
FROM tblProcedure
WHERE (((tblProcedure.Status)="Inactive"));

Trim Diagnosis Catalog ID's

UPDATE tblDiagnosis SET tblDiagnosis.ID = Trim([tblDiagnosis].[ID]), tblDiagnosis.ICD = Trim([tblDiagnosis].[ICD]), tblDiagnosis.Brief = Trim([tblDiagnosis].[Brief]);

Trim Procedure Catalog ID's

UPDATE tblProcedure SET tblProcedure.CPT = Trim([tblProcedure].[CPT]), tblProcedure.ID = Trim([tblProcedure].[ID]), tblProcedure.Description = Trim([tblProcedure].[Description]);

Trim Insurance Payer city, company name and ZIP codes

UPDATE tblCarrier SET tblCarrier.City = Trim([tblCarrier].[City]), tblCarrier.Company = Trim([tblCarrier].[Company]), tblCarrier.Zip = Trim([tblCarrier].[Zip]);
 

Change "Bill To" to "Either" in the Procedure Catalog

UPDATE tblProcedure SET tblProcedure.BillTo = 2
WHERE (((tblProcedure.Category)>18));

Make all EMR Datacenter appointment plans & mapping available for MyEMR verbiage.

UPDATE tblCPVModality SET tblCPVModality.Owner = "*PUBLIC";

Change diagnosis full description from NULL to blank.

UPDATE tblDiagnosis SET tblDiagnosis.Full = ""
WHERE (((tblDiagnosis.Full) Is Null));

Turn off patient tracers for all insurance policies.  The asterisk character may be substituted for the computer key ID of the insurance payer for surgical changes, for example, the "*" could be substituted for "BCBS" if you had an insurance payer with the computer key ID of "BCBS".

UPDATE tblThirdParty SET tblThirdParty.TracePat = 0
WHERE (([tblThirdParty].[ID]="*"));

Revert transactions to assigned type if the insurance policy assignment flag is checked.

UPDATE (tblTransaction INNER JOIN tblClaim ON tblTransaction.OnClaim = tblClaim.Created) INNER JOIN tblClaimCarrierDetail ON (tblClaim.CarrierCreated = tblClaimCarrierDetail.CarrierCreated) AND (tblClaim.CarrierDetail = tblClaimCarrierDetail.CarrierModified) SET tblTransaction.Assigned = True
WHERE (((tblTransaction.Assigned)=False) AND ((tblTransaction.AccountingType)="S") AND ((tblClaimCarrierDetail.BenAsn)=1)) OR (((tblTransaction.Assigned)=False) AND ((tblTransaction.AccountingType)="P") AND ((tblClaimCarrierDetail.BenAsn)=1));
 

Insert new item into the appointment resolution log

INSERT INTO tblLogGlossary ( Section, Type, Sequence, [Text], Action, ReplicationModified )
VALUES (0, 1 , 0 , "Canceled: Would not reschedule", 2, Now())

Remove any SOAP window records with future dates as the result of the computer time clock being set to a future date.

DELETE CP_DSD.Created
FROM CP_DSD
WHERE (((CP_DSD.Created)>Now()));

Delete appointment blackout for a provider for a day.  Substitute XYZ with the provider ID, and substitute the date range of 12/30/2006 and 12/31/2006 with the desired date range.  Note that 12/30/2006 and 12/31/2006 represent exactly midnight for an exact 24 hour range.

DELETE tblAppointment.Chart, tblAppointment.Provider, tblAppointment.Apt
FROM tblAppointment
WHERE (((tblAppointment.Chart)="%%Blackout") AND ((tblAppointment.Provider)="XYZ") AND ((tblAppointment.Apt)>#12/30/2006# And (tblAppointment.Apt)<#12/31/2006#));

If a claim has been deleted, return orphaned transactions to an unbatched status.

UPDATE tblTransaction LEFT JOIN tblClaim ON tblTransaction.OnClaim = tblClaim.Created SET tblTransaction.OnClaim = #1/1/1901#
WHERE (((tblTransaction.OnClaim) Is Not Null));

Delete blank Rich Text Format notes.

DELETE CP_DSIRTF.binNote
FROM CP_DSIRTF
WHERE (((CP_DSIRTF.binNote) Is Null));

Delete Rich Text Format notes with invalid audio/ink annotation values.

DELETE CP_DSIRTF.NoteAnnotateMask
FROM CP_DSIRTF
WHERE (((CP_DSIRTF.NoteAnnotateMask)>2));

Delete a patient's most recent objective spinal palpation record.  Substitute the desired chart number in place of 2006-?????.

DELETE CP_DSD.Chart
FROM (SELECT TOP 1 CP_DSD.Chart, CP_DSD.Type, CP_DSD.ReplicationModified
FROM CP_DSD
WHERE (((CP_DSD.Chart)="2006-?????") AND ((CP_DSD.Type)="OP"))
ORDER BY CP_DSD.Chart, CP_DSD.Type, CP_DSD.ReplicationModified DESC)

5 queries to delete all transactions & history and claims and history.

zero_balances.txt

29 queries to delete all patient data except for customized verbiage

clear_queries.txt

After copying the desired query to the clipboard, right-click and "Paste" the query into the Free Form window as in the figure below.

 

Data conversion queries:  Description

SQL Command (Drag select and copy to your clipboard.)

Internal Use Only

UPDATE tblFinancial SET tblFinancial.Receipt = 0;
 

Internal Use Only

UPDATE tblCarrier SET tblCarrier.HCFARelateDX = 3;

Change "Bill To" to "Either" in the Procedure Catalog

UPDATE tblProcedure SET tblProcedure.BillTo = 2
WHERE (((tblProcedure.Category)>18));

Internal Use Only.  Set default schedule from provider *TEMP to provider "DOC1".

UPDATE tblSchedule SET tblSchedule.Provider = "DOC1";


 Print   
Copyright ©2003-2008 by Software Motif, Inc.   Terms Of Use  Privacy Statement