Wednesday, November 11, 2020

Digi-Key Double Quotes Bug

On or about 11/09/2020 Digi-Key starting displaying double quotes "" in the Size / Dimension and Height fields. 

click on image to view


As shown below Parts converts single quotes and double quotes to in (for inches) 




Example Digi-Key Link: https://www.digikey.com/en/products/detail/hammond-manufacturing/1455K1202/460165

Notes:

Importing and exporting CSV data files with quote characters can cause problems.

Quotes are used to qualify (enclose) strings along with delimiters (field separators) i.e. tab or comma characters in CSV data files.

Tip: Use Part's Excel Import and Export features to avoid CSV file related issues.

That's it !


Monday, October 19, 2020

Create and Connect to a MySQL Database with Amazon RDS

A cloud hosted MySQL database enables remote team members to create and share a centralized Altium database library.

How to Create a MySQL Database – Amazon Web Services

Inbound Traffic Rule

IPv4, MySQL/Aurora, TCP, 3306, 0.0.0.0/0

Importing data into a MySQL DB instance

Amazon AWS > MySQL has an inactive connection time out. 

This timeout is set in the online AWS account for the database.

That's it !

Saturday, October 17, 2020

SQL Query

This is a Part Librarian Feature.

Copy and Paste one the examples below to the Parts SQL Query form.  

Edit the query statement as needed then select Run SQL Query.

Leave me a comment if you have a favorite query and I'll add it to this growing list.

Thank you for your support
Randy

SELECT *
FROM parts
WHERE parts.[Lib Report] <> ''
ORDER BY parts.[Lib Report];

SELECT *
FROM parts
WHERE parts.Part_Type="Resistor" OR parts.Part_Type="Capacitor" OR parts.Part_Type="Inductor";

SELECT *
FROM parts
WHERE parts.[Lib Report] Like '*'
ORDER BY parts.[Lib Report];

SELECT * 
FROM parts
WHERE ID >= 30015
ORDER BY parts.ID;

SELECT *
FROM parts
WHERE ID BETWEEN 30015 AND 30022;

SELECT *
FROM parts
WHERE parts.[Updated By] LIKE 'rclemmons' AND parts.ID BETWEEN 30015 AND 30022
ORDER BY parts.ID;

SELECT *
FROM parts
WHERE parts.[Updated By] LIKE 'rclemmons' AND parts.[Updated_Date] LIKE '*2020-10-19*'
ORDER BY parts.[ID], parts.[Updated By], parts.[Updated_Date];

SELECT *
FROM parts
WHERE Updated_Date >= '2020-10-16' AND Updated_Date <= '2021-11-16'
ORDER By parts.[Updated_Date];

SELECT *
FROM parts
WHERE parts.[Updated By] LIKE 'rclemmons' AND Updated_Date >= '*2025-09-12*'
ORDER By parts.[Updated_Date];

SELECT *
FROM parts
WHERE parts.[Created By] = 'rclemmons' AND parts.Value = '1K'
ORDER BY parts.ID;

SELECT *
FROM parts
WHERE [Created By] = 'rclemmons'
AND ([Updated By] IS NULL OR [Updated By] = '')
ORDER BY Created_Date ASC;

MS Access Examples using Brackets and Quotes: (Librarian Only)

UPDATE Parts SET Parts.[Supplier 1] = "";
UPDATE parts SET Parts.[Supplier 1] = 'DigiKey';

UPDATE parts SET parts.[Supplier 1] = 'DigiKey' WHERE parts.[Supplier 1] is NULL;
UPDATE parts SET parts.[Supplier 1] = 'DigiKey' WHERE parts.[Supplier 1] = 'Digi-Key';

DELETE FROM parts WHERE ID = 30512;
INSERT INTO parts (ID) VALUES (30512);

Select * FROM parts WHERE Sorted_Value IS NULL;
UPDATE parts SET Sorted_Value = 0


'Delete All Records in the Parts Table ! ! ! Warning ! ! !
DELETE FROM parts;

DELETE FROM parts WHERE ID <= 30015;

DELETE FROM parts WHERE ID > 30817;


MySQL Syntax with `accent characters and Single Quotes` : (Librarian Only)

'Delete All Records in the Parts Table ! ! ! Warning ! ! !
TRUNCATE parts.parts

UPDATE parts SET `Symbol Ref` = `Library Ref` WHERE `Symbol Ref` <> `Library Ref`;

UPDATE parts SET `Supplier 1` = ''
UPDATE parts SET `Supplier 1` = '' WHERE `Supplier 1` = 'DigiKey';
UPDATE parts SET `Supplier 1` = 'DigiKey' WHERE `Supplier 1` = '';

UPDATE parts SET `Supplier 1` = NULL
UPDATE parts SET `Supplier 1` = NULL WHERE `Supplier 1` = 'DigiKey';
UPDATE parts SET `Supplier 1` = 'DigiKey' WHERE `Supplier 1` IS NULL;

UPDATE parts SET `Supplier 1` = 'DigiKey' WHERE `Supplier 1` = 'Digi-Key';

'Adjust LIMIT equal to Row Count
UPDATE parts SET Sorted_Value = 0 WHERE Sorted_Value IS Null LIMIT 10000;

'Rename parts table field `Manufacturer Part Number` TO `Mfr Part Number`
ALTER TABLE parts 
RENAME COLUMN `Manufacturer Part Number` TO `Mfr Part Number`

That's It !